package com.aspyn.toasttime;

import android.app.Activity;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.TextView;
import android.widget.Toast;

public class ToastTimeActivity extends Activity implements OnClickListener {
    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
        
        Button btn = (Button)findViewById(R.id.btnToast);
        btn.setOnClickListener(this);
    }

	public void onClick(View v) {
		// TODO Auto-generated method stub
		TextView tv = (TextView)findViewById(R.id.txtEnterToast);
		
		Toast.makeText(this, tv.getText().toString(), Toast.LENGTH_LONG).show();
	}
}